// void, Obj This


Building this;
int nFeedingInterval, i;
ObjList ol;

Sleep(9080+rand(GetConst("RandTimeStart"))+GetConst("AddTimeStart"));

this = This.AsBuilding();
nFeedingInterval = GetConst("DropFoodByOneIvl");

if (!.settlement.IsIndependent()) 
	Sleep(20000);

while (.settlement.IsIndependent()) {
	//feed the teutons inside
	ol = .settlement.Units();

	for (i=0; i<ol.count; i+=1) {
		if(ol[i].AsUnit.IsValid)
			ol[i].AsUnit.SetFood(20);
	}
	Sleep(nFeedingInterval*3);
}
